package com.chmingx.boot.bean;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

import java.util.*;

@ConfigurationProperties(prefix = "student")
@Component
public class Student {
    private String name;
    private Boolean gender;
    private int age;
    private Date birth;
    private Pet pet;
    private String[] hobbies;
    private List<String> books;
    private Map<String, Float> scores;
    private Set<String> subjects;
    private Map<String, List<Pet>> classmatePets;

    @Override
    public String toString() {
        return "Student{" +
                "name='" + name + '\'' +
                ", gender=" + gender +
                ", age=" + age +
                ", birth=" + birth +
                ", pet=" + pet +
                ", hobbies=" + Arrays.toString(hobbies) +
                ", books=" + books +
                ", scores=" + scores +
                ", subjects=" + subjects +
                ", classmatePets=" + classmatePets +
                '}';
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Boolean getGender() {
        return gender;
    }

    public void setGender(Boolean gender) {
        this.gender = gender;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public Date getBirth() {
        return birth;
    }

    public void setBirth(Date birth) {
        this.birth = birth;
    }

    public Pet getPet() {
        return pet;
    }

    public void setPet(Pet pet) {
        this.pet = pet;
    }

    public String[] getHobbies() {
        return hobbies;
    }

    public void setHobbies(String[] hobbies) {
        this.hobbies = hobbies;
    }

    public List<String> getBooks() {
        return books;
    }

    public void setBooks(List<String> books) {
        this.books = books;
    }

    public Map<String, Float> getScores() {
        return scores;
    }

    public void setScores(Map<String, Float> scores) {
        this.scores = scores;
    }

    public Set<String> getSubjects() {
        return subjects;
    }

    public void setSubjects(Set<String> subjects) {
        this.subjects = subjects;
    }

    public Map<String, List<Pet>> getClassmatePets() {
        return classmatePets;
    }

    public void setClassmatePets(Map<String, List<Pet>> classmatePets) {
        this.classmatePets = classmatePets;
    }
}
